var status = -1;
var selectionLog = [];

function start() {
    action(1, 0, 0)
}

function action(e, c, b) {
    if (status == 0 && e == 0) {
        im.dispose();
        return
    }(e == 1) ? status++ : status--;
    selectionLog[status] = b;
    var a = -1;
    if (status <= a++) {
        im.dispose()
    } else {
        if (status === a++) {
            var d = im.getNumberFromQuestCustomData(163071);
            if (new Date().getTime() - d > 60000) {
                im.setNumberForQuestInfo(63260, "buff", 0)
            }
            im.setNumberForQuestCustomData(163071, new Date().getTime());
            var f = im.addNumberForQuestInfo(63260, "buff", 1, 1, 3) + 1;
            if (f > 2) {
                im.dispelBuff(2003602 + f - 1)
            }
            im.useItem(2003602 + f, false);
            im.playerMessage(5, "身体好像变大了" + f + "倍左右。");
            if (im.isQuestActive(63071)) {
                if (f < 4) {
                    im.sendNormalTalk("#b看样子我再变大一点就能搞定了……\r\n再吃点#t2436086#吧？", 2, 0, false, true)
                } else {
                    im.sendNormalTalk("#b好像没法变得更大了。", 2, 0, false, true)
                }
            }
            im.gainItem(2436086, -1);
            im.dispose()
        }
    }
};